package com.utils;

import javax.swing.JOptionPane;

/**
 * @author sad
 */
public class Utils {
    public static void showError(String message){
        JOptionPane.showMessageDialog(null, message, "Error", JOptionPane.ERROR_MESSAGE);
    }
    
    public static int unsignedByte(byte value) {
        return value & 0xff;
    }


    public static int lhTo16Bit(byte l, byte h) {
        return (unsignedByte(h) << 8) | unsignedByte(l);
    }
}
